package com.xzx.redisstudy;


import redis.clients.jedis.Jedis;

/**
 * @author xinzhixuan
 * @version 1.0
 * @date 2021-05-23 3:47 下午
 */
public class FirstDemo {
    public static void main(String[] args) {
        Jedis jedis = new Jedis("localhost", 6379);
        String pong = jedis.ping();
        System.out.println(pong);

        jedis.set("k1", "v1");
        String v1 = jedis.get("k1");
        System.out.println(v1);
        jedis.close();
    }
}
